import {IS_IOS} from "../style/constant";
import HUDProgress, {SVProgressHUDMaskType} from "../component/native/HUDProgress";
import {YellowBox} from "react-native";
import {dev} from "./index";

export default function initializeConfig() {
    if (IS_IOS&&HUDProgress) {
        HUDProgress.setMinimumSize(120, 120);
        HUDProgress.setDefaultMaskType(SVProgressHUDMaskType.SVProgressHUDMaskTypeBlack);
    }
    if (!dev) {
        console.log = function () {
        };
    }
    YellowBox.ignoreWarnings(['Warning: isMounted(...) is deprecated', 'Module RCTImageLoader']);
    YellowBox.ignoreWarnings([`Module RCTAlipay requires main queue setup since it overrides \`constantsToExport\` but doesn't implement \`requiresMainQueueSetup\`. In a future release React Native will default to initializing all native modules on a background thread unless explicitly opted-out of.`]);
    YellowBox.ignoreWarnings([`Module RCTWeChat requires main queue setup since it overrides \`init\` but doesn't implement \`requiresMainQueueSetup\`. In a future release React Native will default to initializing all native modules on a background thread unless explicitly opted-out of.`]);
    YellowBox.ignoreWarnings(['Class RCTCxxModule']);

}